/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package devbureau.fstore.common.report;

import java.util.Date;
import static devbureau.fstore.util.Utilities.DateTime.formatShort;
import static devbureau.fstore.util.Utilities.Formatting.formatAsCurrency;
/**
 *
 * @author SSheypak
 */
public class Bill {
    private Integer orderId;
    private String customerLabel;
    private Integer qtty;
    private Date date;
    private Double price;
    private Double percent;

    public Bill(Integer orderId, String customerLabel, Integer qtty, Date date, Double price, Double percent) {
        this.orderId = orderId;
        this.customerLabel = customerLabel;
        this.qtty = qtty;
        this.date = date;
        this.price = price;
        this.percent = percent;
    }



    public String getCustomerLabel() {
        return customerLabel;
    }

    public void setCustomerLabel(String customerLabel) {
        this.customerLabel = customerLabel;
    }

    public Integer getOrderId() {
        return orderId;
    }

    public void setOrderId(Integer orderId) {
        this.orderId = orderId;
    }

    public Date getDate() {
        return date;
    }

    public void setDate(Date date) {
        this.date = date;
    }

    
    public Double getPercent() {
        return percent;
    }

    public void setPercent(Double percent) {
        this.percent = percent;
    }

    public Double getPrice() {
        return price;
    }

    public void setPrice(Double price) {
        this.price = price;
    }

    public Integer getQtty() {
        return qtty;
    }

    public void setQtty(Integer qtty) {
        this.qtty = qtty;
    }

    public String[] getValuesForXLSReport(){
        String[] values = new String[]{
            orderId.toString(),
            customerLabel,
            qtty.toString(),
            devbureau.fstore.util.Utilities.DateTime.formatShort(date),
            formatAsCurrency(percent),//4
            formatAsCurrency(price),//5
            formatAsCurrency(new Double(percent-price)),//6
        };

        return values;
    }
}
